package cn.heiliu.selenium;

import cn.heiliu.selenium.config.SetupConfig;
import cn.heiliu.selenium.service.IWebDriverCreateService;
import cn.heiliu.selenium.service.IWebDriverService;
import cn.heiliu.selenium.service.impl.FirefoxWebDriverCreateServiceImpl;

/**
 * @author wangyelou
 * @date 2021/6/14
 */
public class GetSingleWebDriver {

    public static void main(String[] args) {
        SetupConfig setupConfig = SetupConfig.builder().binPath("C:\\Program Files\\Mozilla Firefox\\firefox.exe")
                .enginePath("D:\\work\\firefox-selenium\\geckodriver.exe")
                .proxyAuthExt("D:\\work\\firefox-selenium\\firefox_proxy_auth.xpi").build();

        IWebDriverService webDriver = SeleniumManager.createFirefoxSelenium(setupConfig);
        webDriver.fetch("http://www.baidu.com/");

    }

}
